﻿using Abp.Domain.Entities;
using Abp.Domain.Entities.Auditing;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace RMM.Core.Entity.Attachments
{
    /// <summary>
    /// 附件表
    /// </summary>
    [Table("RMM_Attachment")]
    public class Attachment : Entity<long> , ICreationAudited
    {
        /// <summary>
        /// 对象id
        /// </summary>
        public long ObjectId { get; set; }

        /// <summary>
        /// 文件类型 1：图片 2：视频 默认1
        /// </summary>
        public int MediaType { get; set; }

        /// <summary>
        /// 路径
        /// </summary>
        public string FilePath { get; set; }

        /// <summary>
        /// 权重 从大到小
        /// </summary>
        public bool IsDefault { get; set; }


        public Attachment()
        {
            MediaType = 1;
            IsDefault = false;
        }



        public long? CreatorUserId { get  ; set  ; }
        public DateTime CreationTime { get  ; set  ; }
    }
}
